package com.qn.validation.annotation;

import com.qn.validation.helper.FieldScopeValidator;
import jakarta.validation.Constraint;
import jakarta.validation.Payload;

import java.lang.annotation.*;

/**
 * 字段范围
 *
 * @author QN
 * @date 2024/12/31
 */
@Documented
@Target({ElementType.FIELD})
@Retention(RetentionPolicy.RUNTIME)
@Constraint(validatedBy = FieldScopeValidator.class)
public @interface FieldScope {

    String[] in() default {};

    String message() default "";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};

}
